<template>
	<view class="logistics-box">
		<view class="title">
			{{logisticsOrderNo}} 物流信息
		</view>
		<view class="con">
			<order-logistics ref="orderLogistics"></order-logistics>
		</view>
	</view>
</template>

<script>
	import orderLogistics from '../../components/order_logistics.vue'
export default {
	name:'member-order-order_logistics',
	components:{
		orderLogistics
	},
	data() {
		return {
			logisticsOrderNo:'',
		};
	},
	onLoad() {
		console.log(this.$Route.query)
		const q = this.$Route.query
		if (q && q.id) {
			this.getData(q.id)
		}
	},
	methods: {
		getData(_orderId){
			this.$api.order.getLogistics({order_id:_orderId}).then(res => {
				this.logisticsOrderNo = res.order_no
				this.$refs['orderLogistics'].setData(res)
			})
		},
	}
}
</script>

<style lang="scss" scoped>
	.logistics-box{
		// padding: 30rpx 30rpx 0;
		overflow: hidden;
		padding-bottom: 30rpx;
		
		.title{
			font-size: 32rpx;
			height: 100rpx;
			line-height: 100rpx;
			padding-left: 30rpx;
			border: 1px solid #CCC;
		}
	}
</style>
